/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package mascotrin;

import java.awt.Graphics;
import java.net.URL;
import javax.swing.ImageIcon;

/**
 *
 * @author SQL
 */
public class ImagenFondo extends javax.swing.JPanel{
  
    public ImagenFondo(){
           this.setSize(400,400);
    }
            
    @Override
    public void paintComponent(Graphics g)
    {
    //URL url = getClass().getResource("/doc/example/Example1.gif");    
    URL url = getClass().getResource("MascotaFondo.jpg");    
    ImageIcon imagen = new ImageIcon(url);
    g.drawImage(imagen.getImage(),0,0,420,420,null);
    setOpaque(false);
    super.paintComponent(g);
    }
}
